//
//  InputPayJsonModel.m
//  BaseProject
//
//  Created by 王盼盼 on 2024/9/27.
//  Copyright © 2024 wangpanpan. All rights reserved.
//

#import "InputPayJsonModel.h"

@implementation InputPayJsonModel
- (InputPayFromType)fromType  {
    if ([self.type isEqualToString:@"LKL"]) {
        return InputPayFromTypeLKL;
    } else if ([self.type isEqualToString:@"UNION"]) {
        return InputPayFromTypeUNION;
    }
    return InputPayFromTypeNone;
}
- (NSString *)payMode {
    if (self.orderId != nil && self.orderId.length > 0) {
        if (self.isLater) {
            return @"LATER";
        } else {
            return @"MIDDLE";
        }
    } else {
        return @"PRE";
    }
}
- (BOOL)isJiuDian {
    return [self.hotelPayType isEqualToString:@"PRE_PAY"] || [self.hotelPayType isEqualToString:@"POST_PAY"] || IsStrNotEmpty(self.hotelPayType) || IsStrNotEmpty(self.orderId);
}
@end
